package com.logistics.map.entity.model;


import lombok.Data;
import org.hibernate.validator.internal.engine.messageinterpolation.parser.EscapedState;

import java.util.List;
import java.util.Map;

@Data
public class SiteRow {

    private String id;
    private String name;
    private List<SiteRow> children;

    public SiteRow(String id, String name, List<SiteRow> children){
        this.id = id;
        this.name = name;
        this.children = children;
    }

    public static SiteRow build(String id, String name, List<SiteRow> children){
        return new SiteRow(id, name, children);
    }

    public static SiteRow build(String id, String name){
        return new SiteRow(id, name, null);
    }
}
